#!/bin/env python
#-*- coding:utf-8 -*-

#----------------------------------------------------------------------------
# Name     :      log.py
# Purpose  :      log module for my tool.
# Author   :      Albert cheng
# Created  :      2012-10-29
# Copyright:     (c) 2012 by Albertcheng
# Licence  :      wxWindows license
#----------------------------------------------------------------------------

import time

class Log():
    def __init__(self):
        pass
    def log(self, message):
        
        tm_info = time.gmtime()
        year = tm_info.tm_year
        month = tm_info.tm_mon
        day = tm_info.tm_mday
        hour = tm_info.tm_hour
        minu = tm_info.tm_min
        sec = tm_info.tm_sec
        tm_str = "%s-%s-%s %s:%s:%s" % (year,month,day,hour,minu,sec)
        
        print tm_str,message
